<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
var busyStudent = function(startTime, endTime, queryTime) {
    let count = 0
    for( var i = 0 ; i<startTime.length ; i++ ){
        if( startTime[i] <= queryTime && queryTime <= endTime[i] ){
            count++
        }
    }
    return count
};

var startTime = [1,1,1,1]
var endTime = [1,3,2,4]
var queryTime = 7
console.log(busyStudent(startTime, endTime, queryTime))
    </script>
</body>
</html>